Skip to content

feat: deterministic noise generators - #71

Merged
0717lee merged 1 commit into
mainfrom
feat/noise
Jul 31, 2026
Merged

feat: deterministic noise generators#71
0717lee merged 1 commit into
mainfrom
feat/noise

Conversation

@0717lee

@0717lee 0717lee commented Jul 31, 2026

Copy link
Copy Markdown
Owner

Adds Image::add_gaussian_noise(seed, sigma) and Image::add_salt_pepper(seed, density), driven by a 64-bit LCG (Knuth MMIX constants) so a given seed reproduces the identical image on every backend. Gaussian deviates use the CLT sum-of-12 approximation (branch-free); noise is gray per pixel to avoid color fringes. 6 new tests: seed determinism, seed divergence, zero-mean sanity on mid-gray, sigma/density 0 exact copies, density accounting with both salt and pepper present, and the classic median-cleans-impulse-noise pairing (>=75% removed). 163/163 tests on wasm-gc and js. Closes #68

@0717lee
0717lee merged commit 8138c6a into main Jul 31, 2026
@0717lee
0717lee deleted the feat/noise branch July 31, 2026 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Deterministic noise generators

1 participant